Unique Substrings in Wraparound String problem